import java.awt.Checkbox;
import java.awt.Dimension;

public class JAPI_Checkbox extends Checkbox
{
	private static final long serialVersionUID = -1183002233748427768L;
	
	int w=0,h=0;
		
 	public JAPI_Checkbox(String title)
	{	
		super(title);
	}

	public void setSize(int dw, int dh)
	{
		w = dw>0 ? dw : 0;
		h = dh>0 ? dh : 0;
		super.setSize(w,h);		
	}

	public Dimension getPreferredSize()
	{	
		Dimension dim = super.getPreferredSize();
		dim.width  = w>0 ? w : dim.width;
		dim.height = h>0 ? h : dim.height;
		return(dim);
	}
	
	public Dimension getMinimumSize()
	{
		Dimension dim = super.getMinimumSize();
		dim.width  = w>0 ? w : dim.width;
		dim.height = h>0 ? h : dim.height;
		return(dim);
	}
}